class Solution {
public:
    bool isUnique(string astr) {
        int ret=0;
        for(int i=0;i<astr.size();i++)
        {
            if((ret&(1<<(astr[i]-'a')))!=0) return false;
            else ret|=(1<<(astr[i]-'a'));
        }
        return true;
    }
};
